<template>
  <div class="list">
    <div v-for="(item, index) in list" :key="index">
      <div class="item-title border-bottom">
        <span class="item-icon"></span>
        {{item.title}}
      </div>
      <div v-if="item.children" class="pl">
        <detail-list :list="item.children"></detail-list>
      </div>
    </div>
  </div>
</template>
<script>
export default {
  name:'detailList',
  props: {
    list: Array
  }
}
</script>
<style lang="scss" scoped>
.item-title{
  line-height: .7rem;
  height: .7rem;
  padding: 0 .3rem;
  .item-icon{
    display: inline-block;
    width: .36rem;
    height: .36rem;
    background: url(//s.qunarzz.com/piao/image/touch/sight/detail.png) 0 -.45rem no-repeat;
    margin-right: .1rem;
    background-size: .4rem 3rem;
    position: relative;
    top: .05rem;
  }
}
.pl{
    padding-left: .35rem;
  }
</style>


